﻿<%@ Page  Language="C#" MasterPageFile="~/Views/Shared/Site.Master" Inherits="System.Web.Mvc.ViewPage<Core.DAL.tSite_Convoc>" %>

<asp:Content ID="cHead" ContentPlaceHolderID="cphHead" runat="server">
    <% this.Page.Title = (string)ViewData["PageTitle"]; %>
</asp:Content>

<asp:Content ID="cJScripts" ContentPlaceHolderID="cphJScripts" runat="server">
    <script type="text/javascript">
        $(function() {
            $("#startdate").datepicker({ showAnim: "slideDown" }, $.datepicker.regional['fr']);
            $("#enddate").datepicker({ showAnim: "slideDown" }, $.datepicker.regional['fr']);
            $('#text').wysiwyg();

            $("a.green").click(function () {
                $(this).addClass("loading");
                $('#adminForm form:eq(0)').submit();
            });

            $("a.blue").click(function () {
                $('#adminForm form')[0].reset();
            });
        });
    </script>
</asp:Content>

<asp:Content ID="cMainContent" ContentPlaceHolderID="cphMainContent" runat="server">
<div id="adminForm">
    <%= Html.ValidationSummary(ScoutNET.Resources.Master_Form_ErrorMessage)%>

    <% using (Html.BeginForm()) {%>
        <p>
            <label for="startdate">Date de début :</label>
            <%= Html.TextBox("startdate", Model.StartDate.ToString("dd/MM/yyyy"), new { @class = "calendarInput" })%>
        </p>
        <p>
            <label for="enddate">Date de fin :</label>
            <%= Html.TextBox("enddate", Model.EndDate.ToString("dd/MM/yyyy"), new { @class = "calendarInput" })%>
        </p>
       
        <p>
            <label for="text">Convoc :</label>
            <%= Html.TextArea("text", Model.Convoc, new { style = "width:510px; height:400px; margin-left:150px" })%>
        </p>
        
        <div class="blockButton">
		    <a class="mediumBtn green awesome" href="javascript:void(0);" title="<%= ScoutNET.Resources.Master_Button_Edit %>"><%= ScoutNET.Resources.Master_Button_Edit %></a>
            <a class="mediumBtn blue awesome" href="javascript:void(0);" title="<%= ScoutNET.Resources.Master_Button_Reset %>"><%= ScoutNET.Resources.Master_Button_Reset %></a>
	    </div>
    <% } %>
</div>
</asp:Content>

<asp:Content ID="cAdminMenu" runat="server" ContentPlaceHolderID="cphAdminMenu">
    <% if ((UserType)ViewData["UserType"] != UserType.User){  %>
    <ul id="adminMenu">
        <li class="create"><%= Html.ActionLink(ScoutNET.Resources.Convoc_Index_CreateLink, "Create", new { controller = "Convoc", systemName = (string)ViewData["SystemName"] })%></li>
    </ul>
    <% } %>
</asp:Content>

